package org.liurq.webservice.server;

import javax.jws.WebService;
import java.util.ArrayList;
import java.util.List;

@WebService
public class PersonServiceImpl implements PersonService{



    @Override
    public Person getPersonName(String name) {
        Person p = new Person();
        p.setName(name);
        return p;
    }

    @Override
    public Person getPersonAge(int age) {
        Person p = new Person();
        p.setAge(age);
        return p;
    }

    @Override
    public Person getPersonInfo(String name, int age) {
        Person p = new Person();
        p.setName(name);
        p.setAge(age);
        return p;
    }

    @Override
    public List<Person> getPersonsInfo(String name, int age) {
        List<Person> list = new ArrayList<Person>();
        Person p = new Person();
        p.setName(name);
        p.setAge(age);
        list.add(p);
        list.add(p);
        list.add(p);
        list.add(p);
        list.add(p);
        list.add(p);
        return list;
    }

}
